<?php
// +----------------------------------------------------------------------
// | ThinkPHP [ WE CAN DO IT JUST THINK ]
// +----------------------------------------------------------------------
// | Copyright (c) 2006~2018 http://thinkphp.cn All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: liu21st <liu21st@gmail.com>
// +----------------------------------------------------------------------

use think\Route;

//获取banner表中某个banner及包含的滑动页列表
Route::get('api/:version/banner/:id', 'api/:version.Banner/getBanner');

//获取theme表中的主题列表
Route::get('api/:version/theme', 'api/:version.Theme/getSimpleList');

//获取theme表中某个主题以及主题包含的子商品列表
Route::get('api/:version/theme/:id', 'api/:version.Theme/getComplexOne');

//获取product表中的所有商品列表
Route::get('api/:version/product/recend', 'api/:version.Product/getMostRecend');
Route::get('api/:version/product/categorg/:id', 'api/:version.Product/getAllByCategoryID');
Route::get('api/:version/product/:id', 'api/:version.Product/getOne', [], ['id' => '\d+']);

//获取category表中的所有分类列表
Route::get('api/:version/category', 'api/:version.Category/getAllCategories');

//获取token
Route::post('api/:version/token/user', 'api/:version.Token/getToken');

Route::post('api/:version/address', 'api/:version.Address/createOrUpdateAddress');


Route::get('api/:version/token/test', 'api/:version.Token/test');


